Proper connect_port
[juce-lv2.git] / juce / source / extras / the jucer / src / ui / jucer_TestComponent.h
blob8e218aaa05d6c4c6008153328c95a0248d24487a
1 /*
2 ==============================================================================
4 This file is part of the JUCE library - "Jules' Utility Class Extensions"
5 Copyright 2004-11 by Raw Material Software Ltd.
7 ------------------------------------------------------------------------------
9 JUCE can be redistributed and/or modified under the terms of the GNU General
10 Public License (Version 2), as published by the Free Software Foundation.
11 A copy of the license is included in the JUCE distribution, or can be found
12 online at www.gnu.org/licenses.
14 JUCE is distributed in the hope that it will be useful, but WITHOUT ANY
15 WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
16 A PARTICULAR PURPOSE. See the GNU General Public License for more details.
18 ------------------------------------------------------------------------------
20 To release a closed-source product which uses JUCE, commercial licenses are
21 available: visit www.rawmaterialsoftware.com/juce for more information.
23 ==============================================================================
26 #ifndef __JUCER_TESTCOMPONENT_JUCEHEADER__
27 #define __JUCER_TESTCOMPONENT_JUCEHEADER__
29 #include "../model/jucer_JucerDocument.h"
32 //==============================================================================
33 /**
35 class TestComponent : public Component
37 public:
38 //==============================================================================
39 TestComponent (JucerDocument* const ownerDocument_,
40 JucerDocument* const loadedDocument_,
41 const bool alwaysFillBackground);
43 ~TestComponent();
45 //==============================================================================
46 void setFilename (const String& fn);
47 const String& getFilename() const throw() { return filename; }
49 void setConstructorParams (const String& newParams);
50 const String& getConstructorParams() const throw() { return constructorParams; }
52 const File findFile() const;
54 JucerDocument* getDocument() const throw() { return loadedDocument; }
55 JucerDocument* getOwnerDocument() const throw() { return ownerDocument; }
57 void setToInitialSize();
59 //==============================================================================
60 void paint (Graphics& g);
61 void resized();
63 static void showInDialogBox (JucerDocument& design);
65 // reloads any test comps that need to do so
66 static void reloadAll();
68 private:
69 JucerDocument* ownerDocument;
70 JucerDocument* loadedDocument;
71 String filename, constructorParams;
72 Time lastModificationTime;
73 const bool alwaysFillBackground;
75 void updateContents();
76 void reload();
80 #endif // __JUCER_TESTCOMPONENT_JUCEHEADER__